package com.feeyo.groundservice.recordnfc.model.api

import com.feeyo.groundservice.http.core.HttpResult
import com.feeyo.groundservice.recordnfc.model.GateItemBO
import com.feeyo.groundservice.recordnfc.model.MixNfcTypeBO
import com.feeyo.groundservice.recordnfc.model.NfcCarBO
import com.feeyo.groundservice.recordnfc.model.NfcBindBO
import com.feeyo.groundservice.recordnfc.model.NfcLogBO
import com.feeyo.groundservice.recordnfc.model.NfcUserBO
import com.feeyo.groundservice.recordnfc.model.ParkingBO
import com.feeyo.groundservice.recordnfc.model.TaskBO
import com.feeyo.groundservice.recordnfc.model.UnitItemBO
import retrofit2.http.Body
import retrofit2.http.POST

/**
 *作者：QLH on 2020-12-14
 *描述：录卡部分
 */
internal interface RecorderCardApi {

    /**保障单位**/
    @POST("units/listSimple")
    suspend fun getUnitList(): HttpResult<List<UnitItemBO>>

    /**用户列表**/
    @POST("user/managerList")
    suspend fun getUserList(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<List<NfcUserBO>>

    /**车辆列表**/
    @POST("car/managerList")
    suspend fun getCarList(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<List<NfcCarBO>>

    /**任务列表**/
    @POST("taskConfig/list")
    suspend fun getTaskList(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<TaskBO>

    /**机位列表**/
    @POST("parking/managerList")
    suspend fun getParkingList(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<ParkingBO>

    /**登机口列表**/
    @POST("gate/listSimple")
    suspend fun getGateList(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<List<GateItemBO>>

    /**查询nfc绑定的类型**/
    @POST("base/nfc")
    suspend fun queryNfcBindType(@Body map: Map<String, @JvmSuppressWildcards Any>):HttpResult<MixNfcTypeBO>

    /**更新用户信息**/
    @POST("user/managerUpdate")
    suspend fun updateUser(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<Any>

    /**更新车辆信息**/
    @POST("car/managerUpdate")
    suspend fun updateCar(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<Any>

    /**更新任务 机位 登机口信息**/
    @POST("parking/nfcBind")
    suspend fun updateParkingNfc(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<Any>

    /**nfc管理**/
    @POST("parking/nfcPageList")
    suspend fun getNfcBind(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<NfcBindBO>

    /**nfc操作日志**/
    @POST("log/allList")
    suspend fun getNfcLog(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<NfcLogBO>

    /**nfc解绑**/
    @POST("parking/nfcUnbind")
    suspend fun unbindNfc(@Body map: Map<String, @JvmSuppressWildcards Any>): HttpResult<Any>
}